﻿@{
    ViewBag.ActiveMenu = "Home"; //The menu item will be active for this page.
}

<div>
    <h1>@L("WelcomeMessage")!</h1>
    <p class="lead">@L("Home_ThisIsATemplate")</p>
    <div class="row">
        <div class="col-md-4">
            <h3>ASP.NET MVC</h3>
            <p>
                @L("Home_AspNetDescription")
            </p>
            <a class="btn btn-primary btn-sm" href="http://asp.net/mvc">@L("LearnMore")..</a>
        </div>
        <div class="col-md-4">
            <h3>ASP.NET Boilerplate</h3>
            <p>
                @L("Home_AspNetBoilerplateDescription")
            </p>
            <a class="btn btn-primary btn-sm" href="http://aspnetboilerplate.com">@L("LearnMore")..</a>
        </div>
        <div class="col-md-4">
            <h3>@L("Others")</h3>
            <p>
                @L("Home_OtherTools")
            </p>
        </div>
    </div>
</div>


<script src="~/Scripts/jquery-1.9.1.js"></script>
<script src="~/Scripts/jquery.signalR-2.1.2.min.js"></script>
<script src="~/signalr/hubs"></script>

<script src="~/Abp/Framework/scripts/libs/abp.signalr.js"></script>


<script>
        var chatHub = $.connection.myChatHub; //get a reference to the hub

        chatHub.client.getMessage = function (message) { //register for incoming messages
            console.log('received message: ' + message);
            alert('received message: ' + message);
        };

        abp.event.on('abp.signalr.connected', function () { //register for connect event
            chatHub.server.sendMessage("Hi everybody, I'm connected to the chat!"); //send a message to the server

            alert("Hi everybody, I'm connected to the chat!");
        });
</script>